package com.study.designpatterns.strategy;


import com.study.designpatterns.strategy.behavior.FlyNoWay;
import com.study.designpatterns.strategy.behavior.QuackNoWay;

/**
 * @author: jzhou
 * @date: 2025/6/14-22:10
 * @version: 1.0
 * @description: 诱饵鸭实现类
 */
public class DecoyDuck extends Duck {
    // 诱饵鸭不会飞行，也不会叫
    public DecoyDuck() {
        this.fly = new FlyNoWay();
        this.quack = new QuackNoWay();
    }

    @Override
    public void display() {
        System.out.println("外观是诱饵鸭");
    }
}
